import { _decorator, Component, Node } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('GameStage')
export class GameStage extends Component {

    // 定义每个阶段的游戏分数
    stageScore:number = 2000;
    stage2Switch:boolean = true;

    @property
    stage:number = 1;

    // 根据分数计算游戏阶段
    computeStage(score:number) {
        this.stage = Math.ceil(score / this.stageScore);
    }
}

